how to create dynamic data table